import request from '@neu/biz-core/utils/request'

export const page = (params) => {
  return request({
    url: '/dcvm/api/w/mocks/p',
    params,
    method: 'get'
  })
}

export const create = (data) => {
  return request({
    url: '/dcvm/api/w/mocks',
    data,
    method: 'post'
  })
}

export const remove = (id) => {
  return request({
    url: '/dcvm/api/w/mocks/' + id,
    method: 'delete'
  })
}

export const detail = (id) => {
  return request({
    url: '/dcvm/api/w/mocks/' + id,
    method: 'get'
  })
}

export const update = (id, data) => {
  return request({
    url: '/dcvm/api/w/mocks/' + id,
    data,
    method: 'put'
  })
}

export const mock = (api) => {
  return request({
    url: '/dcvm' + api,
    method: 'get'
  })
}
